Skip to content

feat(schema): Critical Extension Gate + LockedArtifact DAG tracking - #127

Closed
telleroutlook wants to merge 1 commit into
mainfrom
feat/asf-extension-gate-locked-artifact
Closed

feat(schema): Critical Extension Gate + LockedArtifact DAG tracking#127
telleroutlook wants to merge 1 commit into
mainfrom
feat/asf-extension-gate-locked-artifact

Conversation

@telleroutlook

Copy link
Copy Markdown
Contributor

What

Absorbs two proven designs from the ASF (Autonomous Software Factory) protocol spec into wasmagent-protocol, grounded in WasmAgent's provability-first positioning.

agentbom v0.2

Critical Extension Gate (extensions block): CRD-like mechanism where critical: true extensions MUST cause consumers to abort if the namespace is unrecognised. Prevents silent security downgrades — e.g. a Trust Passport requirement being silently dropped when an older runtime processes the BOM.

Permission namespace pattern: permission_layer.granted_scopes items now enforce ^[a-z0-9.-]+:[a-zA-Z0-9.*_/-]+$ (e.g. network.egress:registry.npmjs.org), making permission grants machine-parseable and auditable rather than free-form strings.

aep-record (additive, aep/v0.3)

LockedArtifact ($defs/LockedArtifact): reusable definition requiring output_hash + output_uri.

run_artifacts array: DAG artifact tracking with nine lifecycle states (pending → completed/failed/cancelled). Uses allOf/if/then conditional to enforce LockedArtifact only when state == completed — in-progress artifacts are unconstrained, completed ones are always cryptographically pinned.

Why

The Critical Extension Gate solves a real failure mode: a consumer that does not understand a security-critical extension must not silently succeed. This is the same principle as Kubernetes CRD x-kubernetes-validations — unknown critical extensions abort, not skip.

The LockedArtifact pattern closes the provability gap where an AEP record could claim an artifact was produced without providing any cryptographic evidence. Completed = locked is an invariant, not a suggestion.

Tests

  • 5 new fixtures (2 valid, 3 invalid) covering all new constraints
  • 18/18 JS tests pass
  • Full Python conformance with jsonschema passes

Note: jq reformatted the two modified schema files to expanded style; semantics are unchanged. biome 1.9.4 not available on this host.

…m & aep-record

Absorbs two proven designs from the ASF (Autonomous Software Factory) protocol spec
into wasmagent-protocol, grounded in WasmAgent's provability-first positioning.

## Changes

### agentbom v0.2
-  block: CRD-like mechanism where  extensions MUST
  cause consumers to abort if the namespace is unrecognised. Prevents silent
  security downgrades (e.g. Trust Passport requirements being silently dropped
  when an older runtime processes the BOM).
-  items now enforce the namespace pattern
   (e.g. ),
  making permission grants machine-parseable and auditable.

### aep-record (aep/v0.3, additive)
- : reusable definition requiring  + .
-  array: DAG artifact tracking with nine lifecycle states
  (pending → completed/failed/cancelled). The  conditional
  enforces LockedArtifact only when state == completed — completed artifacts
  are always cryptographically pinned, in-progress ones are not constrained.

## Test fixtures added
- valid: ,
- invalid: ,
  ,

All 18 JS tests and full Python conformance (with jsonschema) pass.

Note: jq reformatted the two modified schema files to expanded style; semantics
are unchanged. biome 1.9.4 (lineWidth: 100) is not installed on this host.
@telleroutlook

Copy link
Copy Markdown
Contributor Author

This PR adds the Critical Extension Gate and LockedArtifact DAG tracking to agentbom and aep-record schemas. It has merge conflicts with main. Please re-open as a fresh issue to be implemented on top of current main if this feature is still needed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant